package com.drguo.higouguo.web;

import javax.servlet.ServletContext;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
/**
 * 项目启动时设置两个全局变量
 * @author guo
 */
public class InitServlet extends HttpServlet {
	public void init() throws ServletException {
		ServletContext context = getServletContext();
		//上下文
		context.setAttribute("base", context.getContextPath());
		//站点名称
		context.setAttribute("site", "hi,购过吗网上商城");
	}
}
